<Schema name="FdtFFFmsSchema" xmlns="urn:schemas-microsoft-com:xml-data" xmlns:dt="urn:schemas-microsoft-com:datatypes" 
    xmlns:fdt="x-schema:FDTDataTypesSchema.xml" 
    xmlns:fftypes="x-schema:FdtFFDataTypesSchema.xml">

	<!--Definition of Attributes-->
	<AttributeType name="schemaVersion" dt:type="string" default="1.21"/>
	<!-- Indicates which option is to be used to open the FMS connection. See FF-588 section 6.5.3.2 -->
	<AttributeType name="connectOption" dt:type="enumeration" dt:values="VCRSelector NMAAccess FBAPConnect"/>
	<!-- See FF-870 section 3.2.6 OD shall be transferred in the short form (false) or in the long form (true). -->
	<AttributeType name="allAttributes" dt:type="boolean"/>
	<!-- See FF-588 section 6.5.3.7.1 - get multiple consecutive OD entries true / false -->
	<AttributeType name="startFlag" dt:type="boolean"/>
	<!-- See FF-870 section 3.2.6 - more object descriptions follow -->
	<AttributeType name="moreFollows" dt:type="boolean"/>
	<!-- See FF-870 section 3.2.6 - number of object descriptions -->
	<AttributeType name="numberOfObjectDescriptions" dt:type="ui1"/>
	<!-- See FF-870 section 3.3.4 - version of the clients Object Dictionary -->
	<AttributeType name="versionOdCalling" dt:type="i2"/>
	<!-- See FF-870 section 3.3.4 - Profile Number of the client. -->
	<AttributeType name="profileNumberCalling" dt:type="ui2"/>
	<!-- See FF-870 section 3.3.4 - Access Protection Supported attribute of the clients OD object description. -->
	<AttributeType name="accessProtectionSupportedCalling" dt:type="boolean"/>
	<!-- See FF-870 section 3.3.4  - password to be used for the access to all objects of the server on this VCR and membership in access groups  -->
	<AttributeType name="passwordAndAccessGroupsCalling" dt:type="bin.hex"/>
	<!-- See FF-870 section 3.3.4 - maximum length of the FMS PDU to be sent on VCR -->
	<AttributeType name="maxFmsPduSendingCalled" dt:type="ui1"/>
	<!-- See FF-870 section 3.3.4 - maximum length of the FMS PDU to be received -->
	<AttributeType name="maxFmsPduReceivingCalled" dt:type="ui1"/>
	<!-- See FF-870 section 3.3.4 - Profile Number of the server. -->
	<AttributeType name="profileNumberCalled" dt:type="ui2"/>
	<!-- See FMS-870 section 3.3.4 - Access Protection Supported attribute of the servers OD object description. -->
	<AttributeType name="accessProtectionSupportedCalled" dt:type="boolean"/>
	<!-- See FMS-870 section 3.3.4  -->
	<AttributeType name="passwordAndAccessGroupsCalled" dt:type="ui2"/>
	<!-- See FMS-870 section 3.6.3.6 - Access groups and access rights. -->
	<AttributeType name="accessProtection" dt:type="bin.hex"/>
	<!--Attributes of element FmsStatusResponse -->
	<!-- See FMS-870 section 3.1.3.1 - state of the communication capabilities of the device. -->
	<AttributeType name="logicalStatus" dt:type="enumeration" dt:values="stateChangesAllowed
	 limitedServicesPermitted odLoadingNonInteracting odLoadingInteracting"/>
	<!-- See FMS-870 section 3.1.3.1 - coarse summary of the state of the real device. -->
	<AttributeType name="physicalStatus" dt:type="enumeration" dt:values="operational
	 partiallyOperational inoperable needsCommissioning"/>
	<!-- See FMS-870 section 3.1.3.1 - local state of the application and the device. -->
	<AttributeType name="localDetail" dt:type="bin.hex"/>
	<!-- Attributes of element FmsIdentifyResponse -->
	<!-- See FMS-870 section 3.1.3.3 - model name -->
	<AttributeType name="modelName" dt:type="string"/>
	<!-- See FMS-870 section 3.1.3.3 - Revision attribute of the VFD. -->
	<AttributeType name="revision" dt:type="string"/>
	<!-- Attribute of element FmsStandardResponse - refers to NULL response according
	     to FF-870 section 10 -->
	<AttributeType name="responseType" dt:type="enumeration" dt:values="FmsWrite FmsDeleteVariableList
         FmsGenericInitiateDownloadSequence FmsGenericDownloadSegment FmsAbort"/>
	<!-- Attributes for elements regarding domain management -->
	<!-- See FMS-870 section 3.4.3.3 - informs client whether or not the server successfully finished the Download.-->
	<AttributeType name="finalResult" dt:type="boolean" default="1"/>
	<!-- Attributes for element FmsServiceError -->
	<!-- See FMS-870 section 6.1-->
	<AttributeType name="additionalCode" dt:type="ui2"/>
	<!-- See FMS-870 section 6.1-->
	<AttributeType name="additionalDescription" dt:type="string"/>
	<!-- Error codes for ErrorInfo element according to FF-870 section 6.1 and 10.1.4.4
		the error code values defined with the attribute errorCode shall comply with the codes defined with  FF-870 section 10.1.4.4  -->
	<AttributeType name="errorCode" dt:type="i1"/>
	<!-- Error classes for ErrorInfo element according to FF-870 section 6.1 and 10.1.4.4 
		 the error class values defined with the attribute errorClass shall comply with the codes defined with  FF-870 section 10.1.4.4 -->
	<AttributeType name="errorClass" dt:type="i1"/>
	<!-- See FMS-870 section 3.3.4.2-->
	<AttributeType name="abortReason" dt:type="ui1"/>
	<AttributeType name="abortIdentifier" dt:type="enumeration" dt:values="FMSUSER FMS FAS DLL"/>
	<AttributeType name="locallyGenerated" dt:type="boolean"/>
	<AttributeType name="abortDetail" dt:type="bin.hex"/>
	<!-- *********************************************************************** -->
	<!--Definition of Elements-->
	<!--	Element VariableName identifies the name for a variable. 
		Used by variable access services - see FF-870 section 3.6.3 and section 10.1.10  -->
	<ElementType name="VariableName" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="fdt:name" required="yes"/>
	</ElementType>
	<!--	Element VariableListName identifies the name of variable list. 
		Used by variable access services - see FF-870 section 3.6.3 and section 10.1.10 
		and OD management service see FF-870 section 3.2.6 -->
	<ElementType name="VariableListName" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="fdt:name" required="yes"/>
	</ElementType>
	<!--	Element DomainName identifies name of a domain. 
		Used by OD management (see FF-870 section 3.2.6) 
		and Domain management services (see FF-870 section 3.4.3) -->
	<ElementType name="DomainName" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="fdt:name" required="yes"/>
	</ElementType>
	<!--	Element EventName identifies name of a event. 
		Used by OD management (see FF-870 section 3.2.6) services -->
	<ElementType name="EventName" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="fdt:name" required="yes"/>
	</ElementType>
	<!--	Element PiName identifies name of a program invocation object. 
		Used by OD management services (see FF-870 section 3.2.6) -->
	<ElementType name="PiName" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="fdt:name" required="yes"/>
	</ElementType>
	<!-- Index, starting with which the object descriptions shall be read. 
		OD management (see FF-870 section 3.2.6) services -->
	<ElementType name="StartIndex" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="fdt:index" required="yes"/>
	</ElementType>
	<!--	Element AccessSpecificationVar - Selection of type of variable access used 
	for variable access services (see FF-870 section 3.6.3)  -->
	<ElementType name="AccessSpecificationVar" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<group order="one" minOccurs="1" maxOccurs="1">
			<element type="fftypes:Index"/>
		</group>
	</ElementType>
	<!--	Element AccessSpecificationVL - Selection of type of variable list access 
		used for service FMS DeleteVariableList  (see FF-870 section 3.6.3.7)  -->
	<ElementType name="AccessSpecificationVL" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<group order="one" minOccurs="1" maxOccurs="1">
			<element type="fftypes:Index"/>
			<element type="VariableListName"/>
		</group>
	</ElementType>
	<!--	Element VariableListItem - Selection of type of variable access 
		used for service FMS DefineVariableList (see FF-870 section 3.6.3.6) 
		see also element FmsDefineVariableListRequest -->
	<ElementType name="VariableListItem" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<group order="one" minOccurs="1" maxOccurs="1">
			<element type="fftypes:Index"/>
			<element type="VariableName"/>
		</group>
	</ElementType>
	<!--	Element AccessSpecificationOd - Selection of type of OD access 
		used by OD management services (see FF-870 section 3.2.6).
		See also element FmsGetOdRequest -->
	<ElementType name="AccessSpecificationOd" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<group order="one" minOccurs="1" maxOccurs="1">
			<element type="fftypes:Index"/>
			<element type="VariableName"/>
			<element type="VariableListName"/>
			<element type="DomainName"/>
			<element type="EventName"/>
			<element type="PiName"/>
			<element type="StartIndex"/>
		</group>
	</ElementType>
	<!--	Element AccessSpecificationDomain - Selection of type of domain access 
		used for Domain management services (see FF-870 section 3.4.3). -->
	<ElementType name="AccessSpecificationDomain" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<group order="one" minOccurs="1" maxOccurs="1">
			<element type="fftypes:Index"/>
			<element type="DomainName"/>
		</group>
	</ElementType>
	<!-- *********************************************************************** -->
	<ElementType name="ErrorDescription" content="eltOnly" model = "closed">
		<!-- Error description shall contain the following entries:
		       One EnumeratorEntry for the error class describing the error class.
		       One EnumeratorEntry for the error code.
		       
		       EnumeratorEntry for error class:
		       EnumeratorEntry/@index - shall contain the error class according to FF-870 section 10.1.4.4 
		       EnumeratorEntry/@name - shall contain a descriptive name of the error class that complies with
		       the error class names defined with FF-870 section 10.1.4.4 (e.g. access).
		       EnumeratorEntry/@descriptor - free description of error class - could also be a localized text.
		       
		       EnumeratorEntry for error code:
		       EnumeratorEntry/@index - shall contain the error code according to FF-870 section 10.1.4.4 
		       EnumeratorEntry/@name - shall contain a descriptive name of the error code that complies with
		       the error code names defined with FF-870 section 10.1.4.4 (e.g. invalid-address).
		       EnumeratorEntry/@descriptor - free description of error code - could also be a localized text.
		-->
		<element type="fdt:EnumeratorEntry" minOccurs="1" maxOccurs="1"/>
		<element type="fdt:EnumeratorEntry" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<!-- ErrorInfo element according to error classes FF-870 section 10.1.4.4 -->
	<ElementType name="ErrorInfo" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="errorClass" required="yes" />
		<attribute type="errorCode" required="yes" />
		<attribute type="additionalCode" required="no"/>
		<attribute type="additionalDescription" required="no"/>
		<!-- optional error description -->
		<element type="ErrorDescription" minOccurs="0" maxOccurs="1"/>
	</ElementType>
	<ElementType name="CommonErrorType" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<element type="ErrorInfo" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="OdErrorType" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<element type="ErrorInfo" minOccurs="1" maxOccurs="1"/>
		<element type="fftypes:Index" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- Context management see FF-870 section 3.3.4 and section 10.1.7 -->
	<ElementType name="FmsInitiateRequest" content="eltOnly" model="closed">
		<!-- Corresponds to Initiate-RequestPDU -->
		<attribute type="fdt:nodeId" required="no"/>
		<attribute type="connectOption" required="yes"/>		
		<!-- this is the FDT communication reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<!-- PD Tag -->
		<attribute type="fdt:tag" required="yes"/>
		<attribute type="versionOdCalling" required="no"/>
		<attribute type="profileNumberCalling" required="no"/>
		<attribute type="accessProtectionSupportedCalling" required="no"/>
		<attribute type="passwordAndAccessGroupsCalling" required="no"/>
		<!-- additional data for FMS Initiate -->
		<element type="fftypes:DataLinkAddress" minOccurs="1" maxOccurs="1"/>
		<element type="fftypes:VfdTag" minOccurs="1" maxOccurs="1"/>
	</ElementType>

	<ElementType name="FmsInitiateResponse" content="empty" model="closed">
		<!-- Corresponds to Initiate-ResponsePDU -->
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="fftypes:versionOd" required="no"/>
		<attribute type="profileNumberCalled" required="no"/>
		<attribute type="accessProtectionSupportedCalled" required="no"/>
		<attribute type="passwordAndAccessGroupsCalled" required="no"/>
	</ElementType>

	<ElementType name="FmsInitiateError" content="eltOnly" model="closed">
		<!-- Corresponds to Initiate-ErrorPDU -->
		<attribute type="fdt:nodeId" required="no"/>
		<!-- Since no FMS connection has been established this is the FDT communication reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="maxFmsPduSendingCalled" required="no"/>
		<attribute type="maxFmsPduReceivingCalled" required="no"/>
		<attribute type="fftypes:fmsFeaturesSupported" required="no"/>
		<element type="CommonErrorType"  minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsAbortRequest" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="abortIdentifier" required="yes"/>
		<attribute type="abortReason" required="yes"/>
		<attribute type="abortDetail" required="no"/>
	</ElementType>
	<!-- Abort response is FmsStandardResponse with responseType = FmsAbort -->
	<!-- FMS abort indication where the device is the source i.e. is not a request issued by the DTM -->
	<ElementType name="FmsAbortIndication" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="locallyGenerated" required="yes"/>
		<attribute type="abortIdentifier" required="yes"/>
		<attribute type="abortReason" required="yes"/>
		<attribute type="abortDetail" required="no"/>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- Element FmsStandardResponse - refers to NULL response according
	     to FF-870 section 10 -->
	<ElementType name="FmsStandardResponse" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="responseType" required="yes"/>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- Element FmsServiceError - refers to FMS ServiceError response according
	     to FF-870 section 10.1.4 -->
	<ElementType name="FmsServiceError" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<group order="one" minOccurs="1" maxOccurs="1">
			<element type="CommonErrorType"/>
			<element type="OdErrorType"/>
		</group>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- VFD Support see FF-870 section 3.1.3 and section 10.1.5 -->
	<ElementType name="FmsStatusRequest" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
	</ElementType>
	<ElementType name="FmsStatusResponse" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="logicalStatus" required="yes"/>
		<attribute type="physicalStatus" required="yes"/>
		<attribute type="localDetail" required="no"/>
	</ElementType>
	<ElementType name="FmsIdentifyRequest" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
	</ElementType>
	<ElementType name="FmsIdentifyResponse" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="fdt:vendor" required="yes"/>
		<attribute type="modelName" required="yes"/>
		<attribute type="revision" required="yes"/>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- Variable access see FF-870 section 3.6.3 and section 10.1.10 -->
	<ElementType name="FmsReadRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="AccessSpecificationVar" minOccurs="1" maxOccurs="1"/>
		<element type="fftypes:SubIndex" minOccurs="0" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsReadResponse" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="fdt:CommunicationData" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsWriteRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="AccessSpecificationVar" minOccurs="1" maxOccurs="1"/>
		<element type="fftypes:SubIndex" minOccurs="0" maxOccurs="1"/>
		<element type="fdt:CommunicationData" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsDefineVariableListRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="accessProtection" required="yes"/>
		<!-- extension as optional byte array -->
		<attribute type="fdt:byteArray" required="no"/>
		<attribute type="fftypes:listCount" required="yes"/>
		<element type="VariableListItem" minOccurs="1" maxOccurs="*"/>
		<element type="VariableListName" minOccurs="0" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsDefineVariableListResponse" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="fftypes:Index" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsDeleteVariableListRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="AccessSpecificationVL" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- OD Management see FF-870 section 3.2.6 and section 10.1.6  -->
	<ElementType name="FmsGetOdRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="allAttributes" required="yes"/>
		<attribute type="startFlag" required="yes"/>
		<element type="AccessSpecificationOd" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsGetOdResponse" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="moreFollows" required="yes"/>
		<attribute type="numberOfObjectDescriptions" required="yes"/>
		<element type="fdt:CommunicationData" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<!-- *********************************************************************** -->
	<!-- Domain management see FF-870 section 3.4.3 and section 10.1.8 -->
	<ElementType name="FmsGenericInitiateDownloadSequenceRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="AccessSpecificationDomain" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsGenericDownloadSegmentRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="moreFollows" required="yes"/>
		<element type="AccessSpecificationDomain" minOccurs="1" maxOccurs="1"/>
		<element type="fdt:CommunicationData" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsGenericTerminateDownloadSequenceRequest" content="eltOnly" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<element type="AccessSpecificationDomain" minOccurs="1" maxOccurs="1"/>
	</ElementType>
	<ElementType name="FmsGenericTerminateDownloadSequenceResponse" content="empty" model="closed">
		<attribute type="fdt:nodeId" required="no"/>
		<!-- this is the FMS connection reference -->
		<attribute type="fftypes:communicationReference" required="yes"/>
		<attribute type="finalResult" required="no"/>
	</ElementType>
	<!-- *********************************************************************** -->
</Schema>
